<?

require_once ("application.list.inc");

global $_GLOBAL_DBH;
global $_OBJECT_IFACE_PANEL;

$indexes = array (
	name=>array (label=>"Name",order=>"DEFAULT",wrapper=>"vmc_icon_category"),
	description=>array (label=>"Description",order=>"DEFAULT",
			callback=>"_template_list_substring",length=>16),
	cdate=>array (label=>"Create Date",order=>"DEFAULT",wrapper=>"vmc_icon_date"),
);

$object_ctl = "/inventory_control/fs_inv_ctl.php?fs_action=view&fs_tab=inv_ctl_categories&fs_tab_option=fs_inv_ctl_categories&";
$list_options = array (
	array (
		label=>"Add A Category",
		link=>"fs_inv_ctl.php?fs_tab=inv_ctl_categories&fs_action=addnew&fs_tab_option=fs_inv_ctl_categories"
	),
);

$_OBJECT_IFACE_LIST = _app_create_list_object (array (
                db_conn=>$_GLOBAL_DBH,
                indexes=>$indexes,
		list_count=>"SELECT COUNT(*) FROM inv_ctl_categories",
		list_select=>"SELECT * FROM inv_ctl_categories",
                list_id=>"lc_inv_ctl_categories",
                list_options=>$list_options,
                primary_key=>"id",
                primary_relation=>"category_id",
                link_options=>$link_options,
                object_ctl=>$object_ctl
));


$_OBJECT_IFACE_TABBING_PANEL->insert_container ($_OBJECT_IFACE_LIST);


?>
